package model;

public class CompositeMarkingTreeElement extends MarkingTreeElement{
	
	private final MarkingTreeElement previousTreeElement;
	
	public CompositeMarkingTreeElement(final Marking marking, final MarkingTreeElement previousTreeElement) {
		super(marking);
		this.previousTreeElement = previousTreeElement;
	}

	@Override
	public boolean containsSubmarkingOfTransitive(final Marking marking) {
		return this.previousTreeElement.containsSubmarkingOf(marking);
	}

	@Override
	protected boolean containsTransitive(final Marking marking) {
		return this.previousTreeElement.contains(marking);
	}

	@Override
	public Marking getStartMarking() {
		return this.previousTreeElement.getStartMarking();
	}
}
